package standart;

import java.util.HashMap;
import java.util.Map;

import com.fasterxml.jackson.annotation.JsonProperty;

public class Student {

	@JsonProperty("tutor")
	private Tutor tutor;
	@JsonProperty("age")
	private String age;

	@JsonProperty("salary")
	private String salary;

	@JsonProperty("id")
	private String id;

	@JsonProperty("firstName")
	private String firstName;

	@JsonProperty("lastName")
	private String lastName;

	public String getFirstName() {
		return firstName;
	}

	public void setFirstName(String firstName) {
		this.firstName = firstName;
	}

	public String getLastName() {
		return lastName;
	}

	public void setLastName(String lastName) {
		this.lastName = lastName;
	}

	public String getAge() {
		return age;
	}

	public void setAge(String age) {
		this.age = age;
	}

	public String getSalary() {
		return salary;
	}

	public void setSalary(String salary) {
		this.salary = salary;
	}

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String toString() {
		return id + " " + firstName + " " + lastName + " " + age + " " + salary
				+ " " + tutor.getSome();
	}

	public Tutor getTutor() {
		return tutor;
	}

	public void setTutor(Tutor tutor) {
		this.tutor = tutor;
	}

	public Map<String, String> getFields() {
		Map<String, String> fields = new HashMap<String, String>();
		fields.put("id", id);
		fields.put("firstName", firstName);
		fields.put("lastName", lastName);
		fields.put("age", age);
		fields.put("salary", salary);
		return fields;

	}

}
